package com.huobao.yunying.adapters;

import com.huobao.yunying.activitys.muyingquan.SheQuXiaoxi;
import com.huobao.yunying.utils.Utils;
import com.huobao.zhangying.R;

import android.content.Context;
import android.text.method.PasswordTransformationMethod;
import android.widget.TextView;
import joanzapata.android.BaseAdapterHelper;
import joanzapata.android.QuickAdapter;

public class Adapter_SheQuXiaoXi_HuiFu extends QuickAdapter<SheQuXiaoxi> {

	public Adapter_SheQuXiaoXi_HuiFu(Context context) {
		super(context, R.layout.item_shequ_xiaoxihuifu);
	}

	@Override
	protected void convert(BaseAdapterHelper arg0, SheQuXiaoxi arg1) {
		TextView tv_name = arg0.getView(R.id.shequxiaoxi_name);
		TextView tv_xiaoxitixing = arg0.getView(R.id.shequxiaoxitixing);
		TextView tv_huifucontent = arg0.getView(R.id.shequhuifu_content);
		TextView tv_yuantie = arg0.getView(R.id.shequxiaoxi_yuantie);
		TextView tv_time = arg0.getView(R.id.shequxiaoxi_huifutime);
		TextView tv_huifu = arg0.getView(R.id.shequxiaoxi_huifu);
		TextView tv_del = arg0.getView(R.id.shequxiaoxi_huifudel);
		if (Utils.isMobileNO(arg1.getName())) {
			tv_name.setText(arg1.getName().substring(0, 2) + "..." + arg1.getName().substring(9, 12));
		} else {
			tv_name.setText(arg1.getName());
		}
		tv_huifucontent.setText(arg1.getComment());
		tv_yuantie.setText(arg1.getTitle());
		tv_time.setText(arg1.getDateline());

	}

	@Override
	public boolean isEnabled(int position) {
		// TODO Auto-generated method stub
		return false;
	}
}
